﻿using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace Devonline.Core;

/// <summary>
/// 授权类型
/// 在用户, 角色, 组织中的身份类型高于 Authorizer 时, 将不在作为内置角色, 不可编辑
/// </summary>
[Description("授权类型"), Flags]
public enum AuthorizeType
{
    /// <summary>
    /// 匿名的
    /// </summary>
    [Display(Name = "匿名")]
    Anonymous = 0x01,
    /// <summary>
    /// 公众的
    /// </summary>
    [Display(Name = "公众")]
    Public = 0x02,
    /// <summary>
    /// 第三方的
    /// </summary>
    [Display(Name = "第三方")]
    ThirdParty = 0x04,
    /// <summary>
    /// 合作方的
    /// </summary>
    [Display(Name = "合作方")]
    Partner = 0x08,
    /// <summary>
    /// 内部的
    /// </summary>
    [Display(Name = "内部")]
    Internal = 0x10,
    /// <summary>
    /// 官方的
    /// </summary>
    [Display(Name = "官方")]
    Official = 0x20,
    /// <summary>
    /// 授权者
    /// </summary>
    [Display(Name = "授权者")]
    Authorizer = 0x40,
    /// <summary>
    /// 管理员的
    /// </summary>
    [Display(Name = "管理员")]
    Administrator = 0x80,
    /// <summary>
    /// 开发使用的
    /// </summary>
    [Display(Name = "开发者")]
    Developer = 0x100,
    /// <summary>
    /// 系统的
    /// </summary>
    [Display(Name = "系统")]
    System = 0x200
}